
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include "iostream"
#include "f_func.h"

using namespace std;

int main(int argc, char* argv[])
{
	
	const char* _f_ = "rebuild";
	FILE* ext;
	struct stat fs_stat;
	int	block_num = 0;
	int i,type;
	string file_name;
	char file_num[300];
	char* zeros;
	
	load_disks();

	if(!(*rebuild_raid_func)())
	{
		
		#ifdef PRINT_MSG
			printf("[%s]: error rebuild raid \n",_f_); 
		#endif
		unload_raid_files();
		return -1;
	}
	cout<<"RAID was rebuilded"<<endl;
	unload_raid_files();
	return 0;
	
	
}

